<!-- HTML header for doxygen 1.8.13-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>MTB CAT1 Peripheral driver library: cy_stc_cryptolite_rsa_pub_key_t Struct Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen_style.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><a href="http://www.cypress.com/"><img alt="Logo" src="IFXCYP_one-line.png"/></a></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">MTB CAT1 Peripheral driver library</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('structcy__stc__cryptolite__rsa__pub__key__t.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-attribs">Data Fields</a>  </div>
  <div class="headertitle">
<div class="title">cy_stc_cryptolite_rsa_pub_key_t Struct Reference<div class="ingroups"><a class="el" href="group__group__cryptolite.html">Cryptolite   (Cryptography)</a> &raquo; <a class="el" href="group__group__cryptolite__data__structures.html">Common Data Structures</a></div></div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">Description</h2>
<div class="textblock"><p>All fields for the context structure are internal. </p>
<p>Firmware never reads or writes these values. Firmware allocates the structure and provides the address of the structure to the driver in the function calls. Firmware must ensure that the defined instance of this structure remains in scope while the drive is in use.</p>
<p>The driver uses this structure to store and manipulate the RSA public key and additional coefficients to accelerate RSA calculation.</p>
<p>RSA key contained from two fields:</p><ul>
<li>n - modulus part of the key</li>
<li>e - exponent part of the key.</li>
</ul>
<p>Other fields are accelerating coefficients and can be calculated by Cy_Cryptolite_Rsa_Coef API.</p>
<dl class="section note"><dt>Note</dt><dd>All the buffers must be 4 byte aligned in the <a class="el" href="structcy__stc__cryptolite__rsa__pub__key__t.html">cy_stc_cryptolite_rsa_pub_key_t</a> and must also be in little-endian order.<br />
 Use Cy_Cryptolite_InvertEndianness function to convert to or from little-endian order. </dd></dl>
</div><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-attribs"></a>
Data Fields</h2></td></tr>
<tr class="memitem:af693adcbc706181816a873bf82107f87"><td class="memItemLeft" align="right" valign="top">uint8_t *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structcy__stc__cryptolite__rsa__pub__key__t.html#af693adcbc706181816a873bf82107f87">moduloPtr</a></td></tr>
<tr class="memdesc:af693adcbc706181816a873bf82107f87"><td class="mdescLeft">&#160;</td><td class="mdescRight">The pointer to the modulus part of public key.  <a href="#af693adcbc706181816a873bf82107f87">More...</a><br /></td></tr>
<tr class="separator:af693adcbc706181816a873bf82107f87"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a25b2b3ed5f3fa29f40b35b5c1d5c3653"><td class="memItemLeft" align="right" valign="top"><a id="a25b2b3ed5f3fa29f40b35b5c1d5c3653"></a>
uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structcy__stc__cryptolite__rsa__pub__key__t.html#a25b2b3ed5f3fa29f40b35b5c1d5c3653">moduloLength</a></td></tr>
<tr class="memdesc:a25b2b3ed5f3fa29f40b35b5c1d5c3653"><td class="mdescLeft">&#160;</td><td class="mdescRight">The modulus length, in bits, maximum supported size is 4096 Bits. <br /></td></tr>
<tr class="separator:a25b2b3ed5f3fa29f40b35b5c1d5c3653"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a891f076d684c41e2e4ac66d36c26ee6b"><td class="memItemLeft" align="right" valign="top"><a id="a891f076d684c41e2e4ac66d36c26ee6b"></a>
uint8_t *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structcy__stc__cryptolite__rsa__pub__key__t.html#a891f076d684c41e2e4ac66d36c26ee6b">pubExpPtr</a></td></tr>
<tr class="memdesc:a891f076d684c41e2e4ac66d36c26ee6b"><td class="mdescLeft">&#160;</td><td class="mdescRight">The pointer to the exponent part of public key. <br /></td></tr>
<tr class="separator:a891f076d684c41e2e4ac66d36c26ee6b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad2e968aebbdebb273ed747807e6c04ec"><td class="memItemLeft" align="right" valign="top"><a id="ad2e968aebbdebb273ed747807e6c04ec"></a>
uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structcy__stc__cryptolite__rsa__pub__key__t.html#ad2e968aebbdebb273ed747807e6c04ec">pubExpLength</a></td></tr>
<tr class="memdesc:ad2e968aebbdebb273ed747807e6c04ec"><td class="mdescLeft">&#160;</td><td class="mdescRight">The exponent length, in bits, maximum supported size is 256Bit. <br /></td></tr>
<tr class="separator:ad2e968aebbdebb273ed747807e6c04ec"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4e3817d3cf87f8ed81a4b6da15e31975"><td class="memItemLeft" align="right" valign="top">uint8_t *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structcy__stc__cryptolite__rsa__pub__key__t.html#a4e3817d3cf87f8ed81a4b6da15e31975">barretCoefPtr</a></td></tr>
<tr class="memdesc:a4e3817d3cf87f8ed81a4b6da15e31975"><td class="mdescLeft">&#160;</td><td class="mdescRight">The pointer to the Barrett coefficient.  <a href="#a4e3817d3cf87f8ed81a4b6da15e31975">More...</a><br /></td></tr>
<tr class="separator:a4e3817d3cf87f8ed81a4b6da15e31975"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a627a3acc79a455458d3648ee618159fe"><td class="memItemLeft" align="right" valign="top">uint8_t *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structcy__stc__cryptolite__rsa__pub__key__t.html#a627a3acc79a455458d3648ee618159fe">inverseModuloPtr</a></td></tr>
<tr class="memdesc:a627a3acc79a455458d3648ee618159fe"><td class="mdescLeft">&#160;</td><td class="mdescRight">The pointer to the binary inverse of the modulo.  <a href="#a627a3acc79a455458d3648ee618159fe">More...</a><br /></td></tr>
<tr class="separator:a627a3acc79a455458d3648ee618159fe"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5706ee614586b82fe6395a4c16223445"><td class="memItemLeft" align="right" valign="top">uint8_t *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structcy__stc__cryptolite__rsa__pub__key__t.html#a5706ee614586b82fe6395a4c16223445">rBarPtr</a></td></tr>
<tr class="memdesc:a5706ee614586b82fe6395a4c16223445"><td class="mdescLeft">&#160;</td><td class="mdescRight">The pointer to the (2^moduloLength mod modulo).  <a href="#a5706ee614586b82fe6395a4c16223445">More...</a><br /></td></tr>
<tr class="separator:a5706ee614586b82fe6395a4c16223445"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4631754f3258238d03dcae107e3a95b7"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structcy__stc__cryptolite__rsa__pub__key__t.html#a4631754f3258238d03dcae107e3a95b7">preCalculatedCoeff</a></td></tr>
<tr class="memdesc:a4631754f3258238d03dcae107e3a95b7"><td class="mdescLeft">&#160;</td><td class="mdescRight">when set to 'true', pre-calculated coefficients must be provided in 'barretCoefPtr, 'inverseModuloPtr' and 'rBarPtr', can be calculated by Cy_Cryptolite_Rsa_Coef API .  <a href="#a4631754f3258238d03dcae107e3a95b7">More...</a><br /></td></tr>
<tr class="separator:a4631754f3258238d03dcae107e3a95b7"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Field Documentation</h2>
<a id="af693adcbc706181816a873bf82107f87"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af693adcbc706181816a873bf82107f87">&#9670;&nbsp;</a></span>moduloPtr</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t* cy_stc_cryptolite_rsa_pub_key_t::moduloPtr</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>The pointer to the modulus part of public key. </p>

</div>
</div>
<a id="a4e3817d3cf87f8ed81a4b6da15e31975"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4e3817d3cf87f8ed81a4b6da15e31975">&#9670;&nbsp;</a></span>barretCoefPtr</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t* cy_stc_cryptolite_rsa_pub_key_t::barretCoefPtr</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>The pointer to the Barrett coefficient. </p>
<p>Memory for it should be allocated by user with size moduloLength + 1. </p>

</div>
</div>
<a id="a627a3acc79a455458d3648ee618159fe"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a627a3acc79a455458d3648ee618159fe">&#9670;&nbsp;</a></span>inverseModuloPtr</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t* cy_stc_cryptolite_rsa_pub_key_t::inverseModuloPtr</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>The pointer to the binary inverse of the modulo. </p>
<p>Memory for it should be allocated by user with size moduloLength. </p>

</div>
</div>
<a id="a5706ee614586b82fe6395a4c16223445"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a5706ee614586b82fe6395a4c16223445">&#9670;&nbsp;</a></span>rBarPtr</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t* cy_stc_cryptolite_rsa_pub_key_t::rBarPtr</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>The pointer to the (2^moduloLength mod modulo). </p>
<p>Memory for it should be allocated by user with size moduloLength </p>

</div>
</div>
<a id="a4631754f3258238d03dcae107e3a95b7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4631754f3258238d03dcae107e3a95b7">&#9670;&nbsp;</a></span>preCalculatedCoeff</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool cy_stc_cryptolite_rsa_pub_key_t::preCalculatedCoeff</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>when set to 'true', pre-calculated coefficients must be provided in 'barretCoefPtr, 'inverseModuloPtr' and 'rBarPtr', can be calculated by Cy_Cryptolite_Rsa_Coef API . </p>
<p>When set to 'false', all the acceleration step coefficients will be calculated as part of <a class="el" href="group__group__cryptolite__lld__asymmetric__functions.html#ga935311182a513548ec08fe3602a61145">Cy_Cryptolite_Rsa_Proc</a> </p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part
<div id="nav-path" class="navpath">
    <ul>
        <li class="footer">
            Generated for <b>MTB CAT1 Peripheral driver library</b> by <b>Cypress Semiconductor Corporation</b>.
            All rights reserved.
        </li>
    </ul>
</div>
-->
</body>
</html>
